#if !GENERATOR

using System;
using System.ComponentModel;
using System.Diagnostics;
using System.Xml.Serialization;
using System.Collections.Generic;

using YF.OneNote;


namespace YF.OneNote.DataTypes
{
  public partial class InsertedFile
  {
    public InsertedFile()
    {
      
	}

    
  
    protected override bool UpdateContents(NotesNode newContent, List<INotesChange> changes)
    {
	  InsertedFile item = (InsertedFile)newContent;
      bool changed = false;

      
      if (pathCache != item.pathCache)
      {
        changed = true;
		
		NotesPropertyChange propertyChange = new NotesPropertyChange();

        propertyChange.ChangeType = NoteChangeType.Changed;
        propertyChange.OldValue = pathCacheField;
        propertyChange.NewValue = item.pathCacheField;
        propertyChange.PropertyName = "pathCache";
        changes.Add(propertyChange);

		
        pathCacheField = item.pathCacheField;
      }

      if (pathSource != item.pathSource)
      {
        changed = true;
		
		NotesPropertyChange propertyChange = new NotesPropertyChange();

        propertyChange.ChangeType = NoteChangeType.Changed;
        propertyChange.OldValue = pathSourceField;
        propertyChange.NewValue = item.pathSourceField;
        propertyChange.PropertyName = "pathSource";
        changes.Add(propertyChange);

		
        pathSourceField = item.pathSourceField;
      }

      if (preferredName != item.preferredName)
      {
        changed = true;
		
		NotesPropertyChange propertyChange = new NotesPropertyChange();

        propertyChange.ChangeType = NoteChangeType.Changed;
        propertyChange.OldValue = preferredNameField;
        propertyChange.NewValue = item.preferredNameField;
        propertyChange.PropertyName = "preferredName";
        changes.Add(propertyChange);

		
        preferredNameField = item.preferredNameField;
      }


      return changed;
    }
  }
}

#endif